package com.mzy.olddate.demo.customexception;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author mzy
 * @Date 2021/7/25 21:52
 * @Version 1.0
 */
// 自定义的异常类
public class MyException extends Exception {

    // 传递数字大于10；
    private int detail;

    public MyException(int message) {
        this.detail = message;
    }


    @Override
    public String toString() {
        return "MyException{" +
                "detail=" + detail +
                '}';
    }
}
